package com.relytosoft.mizar.media.common.config;

import com.relytosoft.mizar.media.common.constant.PropertyConstants;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

/**
 * @author Jierry
 * @version 2022/4/7.
 */
@Component
public class OpenApiProperty {

    public static String openApiUrls;
    public static String appkeys;
    public static String appSecrets;

    @Value("${relytosoft.mizar.media.openApiUrl}")
    private String openApiUrl;

    @PostConstruct
    public void getOpenApiUrl(){
        openApiUrls = this.openApiUrl;
    }

    @Value("${relytosoft.mizar.media.appkey}")
    private String appkey;

    @PostConstruct
    public void getAppkeys(){
        appkeys = this.appkey;
    }

    @Value("${relytosoft.mizar.media.appSecret}")
    private String appSecret;

    @PostConstruct
    public void getAppSecrets(){
        appSecrets = this.appSecret;
    }
}
